home *** CD-ROM | disk | FTP | other *** search
/ BCI NET / BCI NET Dec 94.iso / archives / networking / amitcp / httpd.lha / httpd / cgi-bin / finger < prev   
Encoding:
Text File  |  1994-06-18  |  1.1 KB  |  41 lines

  1. /* finger script for httpd */
  2.  
  3. address command
  4.  
  5. work = "pipe:cgi-finger-" || pragma( "ID" )
  6.  
  7. parse arg user
  8.  
  9. say "Content-type: text/html"
  10. say ""
  11.  
  12. Finger = "amitcp:bin/finger"
  13. Img = '<img src="http://queer.slip.cs.cmu.edu/amlogosmall.gif">'
  14. num = date('D')*96 + (time('M') % 15)
  15. num2= num % 8
  16.  
  17. if exists( Finger )
  18. then do
  19.     if User =  ""
  20.     then do
  21.         say "<TITLE>Arexx Finger Gateway running on an amiga</TITLE>"
  22.         say "<H1>"||Img||"Finger Gateway</H1>"
  23.         say ""
  24.         say "<ISINDEX>"
  25.         say "<p>The time is "||time('Civil')||" on "||date('Normal')||" here in Pittsburgh."
  26.                 say "<p>That means that approximately <b>"||num||"</b>  people, <b>"||num2||"</b> of them children, have been killed by guns in the United States so far this year."
  27.         say '<p>This is a gateway to "finger". It is written in arexx, and running on an amiga.<br>'
  28.                 say 'Type a user@host combination in your browser''s'
  29.         say "search dialog.<P>"
  30.     end
  31.     else do
  32.                 say "<h1>"||Img||"Result of finger "||user||"</h1><hr>"
  33.         say "<PRE>"
  34.         Finger user
  35.                 say "</pre>"
  36.     end
  37. end
  38. else do
  39.     say "Cannot find finger on this system."
  40. end
  41.